Draft Line/pt-br

Draft Line

Menu location
Drafting → Line
2D Drafting → Line
Workbenches
Draft, BIM
Default shortcut
L I
Introduced in version
0.7
See also
Draft Wire

Descrição

The Draft Line command creates a straight line.

A Draft Line is in fact a Draft Wire with only two points.

Line defined by two points

Utilização

See also: Draft Tray, Draft Snap and Draft Constrain.

  1. There are several ways to invoke the command:
    • Press the Line button.
    • Draft: Select the Drafting → Line option from the menu.
    • BIM: Select the 2D Drafting → Line option from the menu.
    • Use the keyboard shortcut: L then I.
  2. The Line task panel opens. See Options for more information.
  3. Pick the first point in the 3D view, or type coordinates and press the Enter point button.
  4. Pick the second point in the 3D view, or type coordinates and press the Enter point button.

Opções

The single character keyboard shortcuts available in the task panel can be changed. See Draft Preferences. The shortcuts mentioned here are the default shortcuts (for version 1.0).

Notas

Preferências

See also: Preferences Editor and Draft Preferences.

Propriedades

See Draft Wire.

Scripting

See also: Autogenerated API documentation and FreeCAD Scripting Basics.

To create a Draft Line use the make_line method (introduced in version 0.19) of the Draft module. This method replaces the deprecated makeLine method.

line = make_line(p1, p2)
line = make_line(LineSegment)
line = make_line(Shape)

Example:

import FreeCAD as App
import Draft

doc = App.newDocument()

p1 = App.Vector(0, 0, 0)
p2 = App.Vector(1000, 500, 0)
p3 = App.Vector(-250, -500, 0)
p4 = App.Vector(500, 1000, 0)

line1 = Draft.make_line(p1, p2)
line2 = Draft.make_line(p3, p4)

doc.recompute()